{include 'admin/layout/header'}
<link rel="stylesheet" href="__ADMIN_STATIC__/css/addContent.css?random={extendSetting('random')}">
<div class="addcontent">
    <form class="ajaxForm" method="post" >
        <table class="table">
            <input type="hidden" name="pid" value="{$pid}" />
            <tr style="background-color: #F5F5F5;">
                <td style="border-right: 0;">
                    <p class="article-status">
                        <span style="font-weight: bold;font-size: 14px;">网站设置</span>
                    </p>
                </td>
                <td style="height: 38px;"></td>
            </tr>
            <tr>
                <td class="tl">
                    <span>网站状态</span>
                </td>
                <td>
                    <p class="article-status">
                        <input name="setting[siteSwitch]" value="1" type="radio" {if (isset($rowData['siteSwitch']) && $rowData['siteSwitch']=='1') } checked  {/if}  >开启
                        <input name="setting[siteSwitch]" value="2" type="radio" {if (isset($rowData['siteSwitch']) && $rowData['siteSwitch']=='2')} checked  {/if} >关闭
                    </p>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>网站名称</span>
                </td>
                <td>
                    <input type="text" name="setting[siteTitle]" value="{$rowData['siteTitle']??''}" class="midium">
                </td>
            </tr>
            <tr class="webUploadBox">
                <td class="tl">
                    <span>网站LOGO</span>
                </td>
                <td>
                    <input class="rendercls long" type="text" name="setting[siteLogo]"  value="{$rowData['siteLogo']??''}">
                    <div class="webUploadFilePicker upload">[选择图片]</div>
                </td>
            </tr>
            <tr class="webUploadBox">
                <td class="tl">
                    <span>地址栏图标</span>
                </td>
                <td>
                    <input class="rendercls long" type="text" name="setting[siteFavicon]" value="{$rowData['siteFavicon']??''}">
                    <div class="webUploadFilePicker upload">[选择图片]</div>
                    <!--<i class="tips1 iconfont icon-yiwen" title="地址栏图标"></i>-->
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>网站网址</span>
                </td>
                <td>
                    <input type="text" name="config[app.url]" value="{config('app.url')}"  class="long" >
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>后台地址</span>
                </td>
                <td>
                    <input type="text" name="setting[backend_name]" value="{$rowData['backend_name']??trim(YIFANG_ROUTE_PREFIX,'/')}" class="long"  >
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>版权信息</span>
                </td>
                <td>
                    <textarea name="setting[copyright]" cols="40" rows="5">{$rowData['copyright']??''}</textarea>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>备案号</span>
                </td>
                <td>
                    <input type="text" name="setting[icp]" value="{$rowData['icp']??''}" class="long">
                </td>
            </tr>
            <!--<tr>-->
                <!--<td class="tl">-->
                    <!--<span>网站默认风格</span>-->
                <!--</td>-->
                <!--<td>-->
                    <!--<select name="setting[siteTemplateStyle]" >-->
                        <!--{if isset($skinList) && $skinList }-->
                        <!--{foreach $skinList $key $val}-->
                        <!--<option value="{$key}"  {if (isset($rowData['siteTemplateStyle']) && $rowData['siteTemplateStyle']==$key) } selected  {/if} >{$val}</option>-->
                        <!--{/foreach}-->
                        <!--{/if}-->
                    <!--</select>-->
                <!--</td>-->
            <!--</tr>-->
            <tr style="background-color: #F5F5F5;">
                <td style="border-right: 0;">
                    <p class="article-status">
                        <span style="font-weight: bold;font-size: 14px;">官方接口设置</span>
                    </p>
                </td>
                <td style="height: 38px;"></td>
            </tr>
            <tr>
                <td class="tl">
                    <span>官网地址</span>
                </td>
                <td>
                    <input type="text" name="config[app.cmsSiteUrl]" value="{config('app.cmsSiteUrl')}"  class="long" >
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>api地址</span>
                </td>
                <td>
                    <input type="text" name="config[app.cmsUrl]" value="{config('app.cmsUrl')}"  class="long" >
                </td>
            </tr>
            <tr style="background-color: #F5F5F5;">
                <td style="border-right: 0;">
                    <p class="article-status">
                        <span style="font-weight: bold;font-size: 14px;">文章设置</span>
                    </p>
                </td>
                <td style="height: 38px;"></td>
            </tr>
            <tr>
                <td class="tl">
                    <span>富文本编辑器</span>
                </td>
                <td>
                    {php  $text_editor=array("kindEditor"=>"kindEditor","ueditor"=>"百度编辑器",);}
                    <select style="width:200px;" name="setting[text_editor]" >
                        {if $text_editor }
                        {foreach $text_editor $key $val}
                        <option value="{$key}"  {if (isset($rowData['text_editor']) && $rowData['text_editor']==$key) } selected  {/if} >{$val}</option>
                        {/foreach}
                        {/if}
                    </select>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>关键词替换</span>
                </td>
                <td>
                    <textarea type="text" name="setting[key_replace]"   style="min-height:150px;" class="long">{$rowData['key_replace']??''}</textarea>
                    <p>PS: 示例 (替换关键词|替换字符串) 测试|* ，多行内容请换行。</p>
                </td>
            </tr>
            <tr style="background-color: #F5F5F5;">
                <td style="border-right: 0;">
                    <p class="article-status">
                        <span style="font-weight: bold;font-size: 14px;">模板设置</span>
                    </p>
                </td>
                <td style="height: 38px;"></td>
            </tr>
            <tr>
                <td class="tl">
                    <span>网站默认模板</span>
                </td>
                <td>
                    <select name="setting[sitePcTemplateDir]" >
                        {if isset($pcDirList) && $pcDirList }
                        {foreach $pcDirList $key $val}
                        <option value="{$key}"  {if (isset($rowData['sitePcTemplateDir']) && $rowData['sitePcTemplateDir']==$key) } selected  {/if} >{$val}</option>
                        {/foreach}
                        {/if}
                    </select>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>手机默认模板</span>
                </td>
                <td>
                    <select name="setting[siteMobileTemplate]">
                        {if isset($mobileDirList) && $mobileDirList }
                        {foreach $mobileDirList $key $val}
                        <option value="{$key}"  {if (isset($rowData['siteMobileTemplate']) && $rowData['siteMobileTemplate']==$key) } selected  {/if} >{$val}</option>
                        {/foreach}
                        {/if}
                    </select>
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>文章内容-404页面</span>
                </td>
                <td>
                    <input type="text" name="setting[article_detail_404]" value="{$rowData['article_detail_404']??''}" class="midium">
                </td>
            </tr>
            <tr style="background-color: #F5F5F5;">
                <td style="border-right: 0;">
                    <p class="article-status">
                        <span style="font-weight: bold;font-size: 14px;">缓存设置</span>
                    </p>
                </td>
                <td style="height: 38px;"></td>
            </tr>
            <tr>
                <td class="tl">
                    <span>网站首页生成html</span>
                </td>
                <td>
                    <input name="setting[indexHtml]"  value="1" type="radio" {if (isset($rowData['indexHtml']) && $rowData['indexHtml']=='1') } checked  {/if} >是
                    <input name="setting[indexHtml]"  value="0" type="radio" {if (isset($rowData['indexHtml']) && $rowData['indexHtml']=='0') } checked  {/if} >否
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>目录首页文件名</span>
                </td>
                <td>
                    <input type="text" name="setting[index_filename]" value="{$rowData['index_filename']??''}" class="midium">
                </td>
            </tr>
            <tr>
                <td class="tl">
                    <span>生成文件扩展名</span>
                </td>
                <td>
                    <select name="setting[fileExtension]">
                        <option {if (isset($rowData['fileExtension']) && $rowData['fileExtension']=='htm') } selected  {/if} value="htm">.htm</option>
                        <option {if (isset($rowData['fileExtension']) && $rowData['fileExtension']=='html') } selected  {/if} value="html">.html</option>
                        <option {if (isset($rowData['fileExtension']) && $rowData['fileExtension']=='shtm') } selected  {/if} value="shtm">.shtm</option>
                        <option {if (isset($rowData['fileExtension']) && $rowData['fileExtension']=='shtml') } selected  {/if} value="shtml">.shtml</option>
                    </select>
                </td>
            </tr>
            <!--<tr style="background-color: #F5F5F5;">-->
                <!--<td style="border-right: 0;">-->
                    <!--<p class="article-status">-->
                        <!--<span style="font-weight: bold;font-size: 14px;">url伪静态</span>-->
                    <!--</p>-->
                <!--</td>-->
                <!--<td style="height: 38px;"></td>-->
            <!--</tr>-->
            <!--<tr>-->
                <!--<td class="tl">-->
                    <!--<span>url模式</span>-->
                <!--</td>-->
                <!--<td>-->
                    <!--<input name="setting[siteUrlType]" disabled value="1" type="radio" {if (isset($rowData['siteUrlType']) && $rowData['siteUrlType']=='1') } checked  {/if} >动态地址-->
                    <!--<input name="setting[siteUrlType]" disabled value="2" type="radio" {if (isset($rowData['siteUrlType']) && $rowData['siteUrlType']=='2') } checked  {/if} >静态地址-->
                    <!--<input name="setting[siteUrlType]" value="3" type="radio"  {if (isset($rowData['siteUrlType']) && $rowData['siteUrlType']=='3') } checked  {else} checked{/if} >伪静态-->
                <!--</td>-->
            <!--</tr>-->
        </table>
        <div class="yifang-button">
            <button class="btns submit ajaxBtn" type="button" data-form=".ajaxForm" data-close="4" data-submit-url="{YIFANG_ROUTE_PREFIX}/setting/recordBatch" >确认提交</button>
        </div>
    </form>
</div>
{include 'admin/layout/file_upload_script_auto'}
{include 'admin/layout/footer'}